﻿<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2">

  <class name="VisualAgile.Model.Task, VisualAgile.Model" table="Task" lazy="true">

    <id name="TaskID" column="TaskID" >
      <generator class="guid.comb"/>
    </id>

    <property name="Name" column="Name"   type="System.String"  />
    <property name="CreateTime" column="CreateTime"   type="System.DateTime"  />
    <property name="Creator" column="Creator"   type="System.String"  />
    <property name="Remaining" column="Remaining"   type="System.Double"  />
    <property name="Evaluation" column="Evaluation"   type="System.Double"  />
    <property name="Beyond" column="Beyond"   type="System.Double"  />
    <property name="Color" column="Color"   type="System.String"  />
    <property name="Primary" column="[Primary]"   type="System.Boolean"  />
    <property name="CreateDate" column="CreateDate"   type="System.DateTime"  />
    <property name="StartDate" column="StartDate"   type="System.DateTime"  />
    <property name="FinishDate" column="FinishDate"   type="System.DateTime"  />
    <property name="Target" column="Target"   type="System.DateTime"  />    
    <property name="Card" column="Card"  type="System.String"  />
    <property name="Observations" column="Observations"   type="System.String"  />    

    <many-to-one name="Status"
          class="VisualAgile.Model.Status,VisualAgile.Model"
          cascade="none"
          column="StatusID"
           />

    <many-to-one name="Story"
         class="VisualAgile.Model.Story,VisualAgile.Model"
         cascade="none"
         column="StoryID"
           />

    <many-to-one name="Consignee"
         class="VisualAgile.Model.User,VisualAgile.Model"
         cascade="none"
         column="Consignee"
           />

    <set lazy="true" inverse="false" table="Actual" cascade="all"  access="field.camelcase-underscore" name="Actuals" >
      <key column="TaskID"/>
      <one-to-many class="VisualAgile.Model.Actual, VisualAgile.Model" />
    </set>
    
    <property name="IterationID" column="IterationID" />
    
  </class>



</hibernate-mapping>

